<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <title>{$setting.site_name}</title>
    <link type="text/css" rel="stylesheet" href="css/mobile/bootstrap.min.css">
    <link type="text/css" rel="stylesheet" href="css/mobile/font-awesome.min.css">
    <link type="text/css" rel="stylesheet" href="css/mobile/layer.css">
    <link type="text/css" rel="stylesheet" href="css/mobile/main.css">
    <script type="text/javascript" src="js/jquery.js"></script>
    <script type="text/javascript" src="js/mobile/form.min.js"></script>
    <script type="text/javascript" src="js/mobile/layer.js"></script>
    <script type="text/javascript" src="js/mobile/base.js"></script>
<style>
.btn-vcode{position:absolute; top:50%; right:8px; margin-top:-15px; height:30px; border:none; background:none; color:#2161b3; outline:none;}
.btn-vcode.dis{color:#999;}
</style>
</head>
<body onload="getVcode('60')">
<div class="container-fluid reg">
    <div class="head">
        <a class="f_l" href="javascript:history.back();" style="width: 30px;font-size: 30px"><i class="icon-angle-left"></i></a>
        <a>设置密码</a>
        <a class="f_r" href="m-index.html" style="width: 40px;font-size: 25px"><i class="icon-home"></i></a>
    </div>
    <div class="con">
        <form>
            <ul>
                <li style="position:relative;"><input id="zcvcode" name="zcvcode" type="text" placeholder="手机验证码" class="form-control input-lg"><input type="button" id="getRegYzm" class="btn-vcode" value="重新获取" onclick="getVcode('10')"></li>
                <li><input id="passwd" name="passwd" type="password" placeholder="密码(6-20位字符)" minlength="6" maxlength="20" class="form-control input-lg"></li>
                <li><input id="passwdse" name="passwdse" type="password" placeholder="再次输入密码" minlength="6" maxlength="20" class="form-control input-lg"></li>
                <li><input name="regBtn" type="button" class="btn btn-primary btn-lg" value="确定" onclick="setpwd();"></li>
            </ul>
        </form>
    </div>
</div>
<div class="footer abs">
    <ul>
        <li><span>手机版</span> | <a href="http://www.jzz555.com" target="_blank">电脑版</a></li>
        <li>易记域名：www.jzz555.com </li>
        <li>© 2017 {$setting.site_name} 版权所有</li>
    </ul>
</div>
<script type="text/javascript">
function getVcode(t){ 
    var getRegYzm = $("#getRegYzm");
    var countdown1 = setInterval(countDown,1000);
    function countDown(){
        t-=1;     
        if(t>0){
            getRegYzm.attr("disabled","disabled");
            getRegYzm.addClass("dis");
            getRegYzm.val(t+"s后重新获取");
        }else{
            clearInterval(countdown1);
            getRegYzm.removeClass("dis");
            getRegYzm.val("重新获取");
            getRegYzm.removeAttr("disabled");
        }
    }
}
    function setpwd() {
        var vcode = $("#zcvcode");
        if(vcode.val() == "") {
            var e = function() {
                vcode.focus();
            };
            lay_msg('请输入手机验证码！', e);
            return false;
        }

        var o_pd = $("#passwd");
        if(o_pd.val() == "") {
            var e = function() {
                o_pd.focus();
            };
            lay_msg('请设置密码！', e);
            return false;
        }
        if(o_pd.val().length < 6) {
            var e = function() {
                o_pd.focus();
            };
            lay_msg('密码至少需要6个字符！', e);
            return false;
        }
        var n_pd = $("#passwdse");
        if(n_pd.val() != o_pd.val()) {
            var e = function() {
                n_pd.focus();
            };
            lay_msg('两次密码输入不一样！', e);
            return false;
        }
    }
</script>
</body>
</html>